using UnityEngine;

public class LightFX : MonoBehaviour
{
	public Light lighting;

	public float IntensityTarget;

	public float Speed = 30f;

	private void Start()
	{
		if (lighting == null)
		{
			lighting = GetComponent<Light>();
		}
	}

	private void Update()
	{
		if (lighting != null)
		{
			lighting.intensity = Mathf.Lerp(lighting.intensity, IntensityTarget, Speed * Time.deltaTime);
		}
	}
}
